﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace SatisKarsilastirma
{
    public partial class frmAyarlar : Form
    {
        public frmAyarlar()
        {
            InitializeComponent();
        }

        private void frmAyarlar_Load(object sender, EventArgs e)
        {
            txtDB.Text = Sessions.Get[Settings.DatabaseName].ToString();
            txtServer.Text = Sessions.Get[Settings.ServerName].ToString();
            txtUser.Text = Sessions.Get[Settings.UserName].ToString();
            txtPass.Text = Sessions.Get[Settings.Password].ToString();
            comboBox1.Text = Sessions.Get[Settings.AuthenticateMode].ToString();
        }

        private void btnGir_Click(object sender, EventArgs e)
        {
            Sessions.Get[Settings.DatabaseName] = txtDB.Text;
            Sessions.Get[Settings.ServerName] = txtServer.Text;
            Sessions.Get[Settings.UserName] = txtUser.Text;
            Sessions.Get[Settings.Password] = txtPass.Text;
            Sessions.Get[Settings.AuthenticateMode] = comboBox1.Text;
            this.DialogResult = System.Windows.Forms.DialogResult.OK;
        }
    }
}
